added SSCLI 1.0
[windows-sources.git] / shared source / wpf / src / host / shimimpl / versionfactory.hxx
bloba74282fba189207962c5d376b3a622a478899c69
1 //------------------------------------------------------------------------
2 //
3 // Copyright (c) Microsoft Corporation. All rights reserved.
4 //
5 // Description:
6 // Defines a factory for CVersion objects
7 //
8 // History:
9 // 2005/06/20 - [....]
10 // Created
11 // 2007/09/20-[....]
12 // Ported Windows->DevDiv. See SourcesHistory.txt.
14 //------------------------------------------------------------------------
16 #pragma once
20 This is where our Avalon policy is implemented. Given a requested version
21 of Avalon, we need to decide which version of Avalon we are actually going
22 to run.
24 The currently implemented policy is as follows:
26 For applications:
28 if the requested version is available, use it
29 else return the latest version
31 For containers
33 always run the latest version
35 Note that this is just the Avalon version; the CLR version will be exactly
36 specified by PresentationHostDLL.dll
40 #include "Precompiled.hxx"
41 #include "..\shared\StringMap.hxx"
43 class CVersionFactory
45 public:
46 static int GetCount();
47 static CVersion* GetVersion(__in_ecount(1) LPCWSTR pwzRequestedVersion, BOOL bDefaultToLatest = TRUE);
48 static CVersion* GetLatestVersion();
50 private:
51 static HRESULT EnsureVersionList();
53 private:
54 static CStringMap<CVersion*>* m_pVersions;
55 static CVersion* m_pLatestVersion;